package indi.jp.project.business.jingying.dao;

import indi.jp.project.business.jingying.pojo.po.ProjectTrackPO;
import indi.jp.project.business.jingying.pojo.po.ProjectTrackRecordPO;
import indi.jp.project.business.jingying.pojo.query.ProjectTrackQuery;
import indi.jp.project.business.jingying.pojo.query.ProjectTrackRecordQuery;
import org.apache.ibatis.annotations.Mapper;

import java.sql.SQLException;
import java.util.List;

/**
 * 项目跟踪
 *
 * @author jiangping
 * @date 2022/6/5
 */
@Mapper
public interface ProjectTrackDAO {

    List<ProjectTrackPO> queryList(ProjectTrackQuery query) throws SQLException;

    int queryCount(ProjectTrackQuery query) throws SQLException;

    int insert(ProjectTrackPO projectTrackPO) throws SQLException;

    int update(ProjectTrackPO projectTrackPO) throws SQLException;

    ProjectTrackPO findById(String id) throws SQLException;

    int deleteById(String id) throws SQLException;

    /**
     * 下面是跟踪记录
     */
    List<ProjectTrackRecordPO> queryRecordList(ProjectTrackRecordQuery query) throws SQLException;

    int queryRecordCount(ProjectTrackRecordQuery query) throws SQLException;

    int insertRecord(ProjectTrackRecordPO projectTrackRecordPO) throws SQLException;

    int updateRecord(ProjectTrackRecordPO projectTrackRecordPO) throws SQLException;

    int deleteRecord(String id) throws SQLException;

    void deleteRecords(String trackId) throws SQLException;

}
